package exp2;


public class TestCycle {
    public static void main(String[] args) {
        Integer[] a = {1, 2, 3, 4, 5};
        int pos = 2;
        Integer[] b = {2, 4, 6, 8, 10};
        int pos1 = -1;
        MyLinkedList<Integer> lA = new MyLinkedList<Integer>();
        MyLinkedList<Integer> lB = new MyLinkedList<Integer>();
        lA.createListWithPoint(a, pos);
        lB.createListWithPoint(b, pos1);

        System.out.println("lA: " + lA.hasCycle());
        System.out.println("lB: " + lB.hasCycle());
    }
}
